#pragma once

#include "DXAMLCommon.h"
#include "XamlSchemaContext.h"

#include "xamltypeinfoprovider.h"
#include "XamlBitSet.h"



class XamlTypeInfoProvider
{
protected: 
	XamlTypeInfoProvider(){};
public: 
	virtual HRESULT Initialize() = 0;
	virtual HRESULT ResolveAssembly(const xshared_ptr<CXString> & inAssemblyName, struct XamlAssemblyToken & outAssemblyToken) = 0;
	virtual HRESULT GetTypeNamespacesForUri(const xshared_ptr<CXString> & inXmlNamespaceUri, struct XamlTypeNamespaceToken * * ppTypeNamespaceTokens, XUINT32 * pcTypeNamespaceTokens) = 0;
	virtual HRESULT GetTypeNamespace(const xshared_ptr<CXString> & inAssemblyName, const xshared_ptr<CXString> & inTypeNamespace, struct XamlTypeNamespaceToken & outTypeNamespaceToken) = 0;
	virtual HRESULT GetTypeNamespace(const xshared_ptr<CXString> & inTypeNamespace, struct XamlTypeNamespaceToken & outTypeNamespaceToken) = 0;
	virtual HRESULT GetTypeNamespaceForType(struct XamlTypeToken sXamlTypeToken, struct XamlTypeNamespaceToken & rXamlTypeNamespaceToken, xshared_ptr<CXString> & outXamlTypeNamespaceName) = 0;
	virtual HRESULT LookupTypeFlags(struct XamlTypeToken sTypeToken, const XamlBitSet<enum BoolTypeBits> & btbLookupValues, XamlBitSet<enum BoolTypeBits> & btbBitsChecked, XamlBitSet<enum BoolTypeBits> & btbReturnValues) = 0;
	virtual HRESULT LookupPropertyFlags(struct XamlPropertyToken sPropertyToken, const XamlBitSet<enum BoolPropertyBits> & bpbLookupValues, XamlBitSet<enum BoolPropertyBits> & bpbBitsChecked, XamlBitSet<enum BoolPropertyBits> & bpbReturnValues) = 0;
	virtual HRESULT ResolveTypeName(struct XamlTypeNamespaceToken inNamespaceToken, const xshared_ptr<CXString> & inTypeName, struct XamlTypeToken & rXamlType) = 0;
	virtual HRESULT ResolvePropertyName(struct XamlTypeToken sTypeToken, const xshared_ptr<CXString> & inPropertyName, struct XamlPropertyToken & outProperty, struct XamlTypeToken & outPropertyTypeToken) = 0;
	virtual HRESULT ResolveDependencyPropertyName(struct XamlTypeToken sTypeToken, const xshared_ptr<CXString> & inPropertyName, struct XamlPropertyToken & outProperty, struct XamlTypeToken & outPropertyTypeToken) = 0;
	virtual HRESULT GetTypeName(struct XamlTypeToken sTypeToken, xshared_ptr<CXString> & outTypeName) = 0;
	virtual HRESULT GetTypeFullName(struct XamlTypeToken sTypeToken, xshared_ptr<CXString> & outTypeFullName) = 0;
	virtual HRESULT GetPropertyName(struct XamlPropertyToken sPropertyToken, xshared_ptr<CXString> & outPropertyName) = 0;
	virtual HRESULT GetBaseType(struct XamlTypeToken sTypeToken, struct XamlTypeToken & rBaseTypeToken) = 0;
	virtual HRESULT GetDeclaringType(struct XamlPropertyToken sPropertyToken, struct XamlTypeToken & rDeclaringTypeToken) = 0;
	virtual HRESULT IsAssignableFrom(struct XamlTypeToken sDerivedTypeToken, struct XamlTypeToken rxtBaseType, XBOOL & bOut) = 0;
	virtual HRESULT GetContentProperty(struct XamlTypeToken sTypeToken, struct XamlPropertyToken & rPropertyToken, struct XamlTypeToken & rContentPropertyTypeToken) = 0;
	virtual HRESULT GetContentWrapper(struct XamlTypeToken sTypeToken, struct XamlTypeToken & rContentWrapperTypeToken) = 0;
	virtual HRESULT GetRuntimeNameProperty(struct XamlTypeToken sTypeToken, struct XamlPropertyToken & rPropertyToken, struct XamlTypeToken & rPropertyTypeToken) = 0;
	virtual HRESULT GetDictionaryKeyProperty(struct XamlTypeToken sTypeToken, struct XamlPropertyToken & rPropertyToken, struct XamlTypeToken & rPropertyTypeToken) = 0;
	virtual HRESULT GetXmlLangProperty(struct XamlTypeToken sTypeToken, struct XamlPropertyToken & rPropertyToken, struct XamlTypeToken & rPropertyTypeToken) = 0;
	virtual HRESULT GetCollectionItemType(struct XamlTypeToken sCollectionTypeToken, struct XamlTypeToken & rCollectionItemTypeToken) = 0;
	virtual HRESULT GetTextSyntaxForType(struct XamlTypeToken sTypeToken, struct XamlTypeToken & rsTextSyntaxTypeToken) = 0;
	virtual HRESULT GetTextSyntaxForProperty(struct XamlPropertyToken sPropertyToken, struct XamlTypeToken & rsTextSyntaxTypeToken) = 0;

};

